﻿@using WineStore.Extends;
@model WineStore.Models.News
@{
    ViewBag.Title = "DeleteNews";
    Layout = "~/Views/Shared/AdminLayout.cshtml";
}
<!-- Table (TABLE) -->
@section Styles
{
     <style type="text/css">
        input, textarea, select {
            padding: 5px;
            border: 1px solid #ccc;
            border-radius: 3px;
            color: #333;
            box-shadow: rgba(0,0,0,0.1)0px 0px 8px;
            -moz-box-shadow: rgba(0,0,0,0.1)0px 0px 8px;
            -webkit-box-shadow: rgba(0,0,0,0.1)0px 0px 8px;
            margin: 5px;
        }

            /*textarea #ckNewsContent_VN{
            width: 1000px;
            height: 100px;
            max-width: 1000px;
            line-height: 18px;
            border-radius: 3px;
            margin: 5px;
        }*/


            input:hover, textarea:hover, select:hover input:focus, textarea:focus, select:focus {
                border-color: 10px solid #C9C9C9;
                box-shadow: rgba(0,0,0,0.2)0px 0px 8px;
                -moz-box-shadow: rgba(0,0,0,0.2)0px 0px 8px;
                -webkit-box-shadow: rgba(0,0,0,0.2)0px 0px 8px;
                border-radius: 3px;
            }

            input .submit {
                height: 38px;
                background-color: #474E69;
                color: #FFF;
                border-radius: 3px;
                -moz-border-radius: 3px;
                -webkit-border-radius: 3px;
                margin: 5px;
            }

        .text-box-con {
            width: 100%;
        }
    </style>
}
@if (Session["Admin"] != null)
{
<h3 class="tit">
    Xóa tin tức
</h3>
<fieldset>
    <legend>Xóa tin tức</legend>
    @using (Html.BeginForm("DeleteNews", "News", FormMethod.Post, new { enctype = "multipart/form-data" }))
    { 
        @Html.HiddenFor(model => model.NewsId)
        <table class="nostyle">
            <tbody>
                <tr>
                    <td>
                        Danh mục tin tức:
                    </td>
                    <td>
                        @ViewBag.CategoryNewsName_VN
                    </td>
                </tr>
                <tr>
                    <td>
                        Tiêu đề:
                    </td>
                    <td>
                        @Html.DisplayFor(model => model.NewsTitle_VN)
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align:middle">
                        Mô tả:
                    </td>
                    <td>
                        @Html.TextAreaFor(model => model.NewsDescription_VN,10, 100,null)
                    </td>
                </tr>
                <tr>
                    <td style="vertical-align: middle;">
                        Ảnh:
                    </td>
                    <td>
                        @Html.ImageFor(model => "../../Content/Images/News/" + model.NewsImage, new { width = "120px", height = "100px", alt = "some alt text" })
                    </td>
                    <td style="color: Red;">
                    </td>
                </tr>
                <tr>
                    <td>
                    </td>
                    <td>
                        <input type="submit" value="Xóa tin tức" style="width: 100px; cursor: pointer;"/>
                    </td>
                </tr>
            </tbody>
        </table>
    }
</fieldset>
}
else
{
    Response.Redirect("~/Admin/LogOn/");
}